﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net.Mail;
using System.Web;

namespace HomeWizardServices
{
    public static class HomeWizardEmail
    {
        public static void SendEmail(string subject, string body)
        {
            try
            {
                SmtpClient smtpClient = new SmtpClient();
                MailMessage message = new MailMessage();
                smtpClient.Host = "mail.anarsolutions.com";
                smtpClient.Port = 25;
                smtpClient.Credentials = new System.Net.NetworkCredential("test@anarsolutions.com", "testanar_1234");

                message.Subject = subject;
                message.Body = body;
                message.From = new MailAddress("test@anarsolutions.com");
                message.To.Add(new MailAddress("jsinger@boston-digital.com"));
                message.To.Add(new MailAddress("laxgulawani@gmail.com"));
                message.To.Add(new MailAddress("harshad.kale@anarsolutions.com"));
                smtpClient.Send(message);
            }
            catch (Exception ex)
            { 
            }
        }
    }
}